import type { Router, RouteRecordRaw } from 'vue-router'

// 权限路由校验
export function generateAccess(router: Router, routes: RouteRecordRaw[]) {
  // TODO
  routes.forEach((itemRouter: any) => {
    if (!router.hasRoute(itemRouter.name)) {
      router.addRoute(itemRouter)
    }
  })
}
